package com.lovesher.payment.common.enums;

public enum SchedulePayResultStatus {
	INIT(0, "初始化"),
	SUCC(1, "成功"),
	FAIL(2, "失败"),
	WAIT(3, "处理中");
	
	private int status;
	private String name;

	private SchedulePayResultStatus(int status, String name) {
		this.status = status;
		this.name = name;
	}

	public int getValue() {
		return this.status;
	}

	public String getName() {
		return this.name;
	}

	public static SchedulePayResultStatus valueOf(int status) {
		SchedulePayResultStatus ret = null;
		for (SchedulePayResultStatus stt : SchedulePayResultStatus.values()) {
			if (stt.getValue() == status) {
				ret = stt;
				break;
			}
		}

		return ret;
	}
}
